import React,{ useState } from "react";
import {Button} from "antd"
require("./add.scss");
function AddNum(params) {
    const [Num,add] = useState("WDNMD");
    const [focus,newFocus] = useState(false);
    let addFun=()=>{
        let addStr = "WOWOOWOOWOWA";
        add(Num+addStr);
    }
    let inputFocus=()=>{
        newFocus(true);
    }
    let inputBlur=()=>{
        newFocus(false);
    }
    return (
        <div>
            <Button type="primary" onClick={addFun}>增加数字{Num}</Button>
            <input type="text" onFocus={inputFocus} onBlur={inputBlur} className={`inputS ${focus?'focus':''}`} placeholder="测试默认字体样式"/>
        </div>
    )
    
    
}
export default AddNum;